<!doctype html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width,initial-scale=1,maximum-scale=1,minimum-scale=1,user-scalable=no"/>

	
<title>悦章科技机构平台</title>	

	
<!--内容样式-->
<link rel="stylesheet" href="__PUBLIC__/Home/css/style.css" />

<link rel="stylesheet" href="__PUBLIC__/Home/css/page.css" />
	
	
</head>

<body>

	
	<div class="main">
	
	
		<!--  头部  -->

		
		
		
		<!--  左侧导航  -->
		<include file="menu" />
		
		
		
		<!--  右侧内容  -->
		<div class="content">
			
			
			<div class= "ct-title">
				<div class="ctt-bt">优惠券管理</div>
				<div class="ctt-r">
					<form class="cttr-bd" action="" method="POST">
						<input type="text" placeholder="请输入优惠券名称" class="cttrb-wb" name="name" value="{$msg['name']}">
						<select class="cttrb-xl" name="status">
							<option value="" >不限</option>
							<option value="1" <if condition="$msg.status eq 1">selected</if>>正常</option>
							<option value="2" <if condition="$msg.status eq 2">selected</if>>停止发券</option>
						</select>
						<button class="cttrb-cx" type="submit">查询</button>
						<a href="{:U('Marketing/addCoupon')}" class="cttrb-xz">新增优惠券</a>
						<div class="divclear"></div>
					</form>
					<div class="divclear"></div>
				</div>
				<div class="divclear"></div>
			</div>
			
			<div class="ct-table">
				<table width="100%" border="0">
					<tbody>
						<tr>
							<th scope="col" width="5%" style="border-top-left-radius: 10px;">ID</th>
							<th scope="col" width="15%">优惠券名称</th>
							<th scope="col" width="20%">优惠内容</th>
							<th scope="col" width="10%">已领取/剩余</th>
							<th scope="col" width="10%">已使用</th>
							<th scope="col" width="10%">状态</th>
							<th scope="col" width="15%">有效期</th>
							<th scope="col" width="15%" style="border-top-right-radius: 10px;">操作</th>
						</tr>
						<volist name="_list" id="item">
							<tr>
							  <td>{$item.id}</td>
							  <td>{$item.name}</td>
							  <td>{$item.type}</td>
							  <td>{$item.received}/{$item.count}</td>
							  <td>{$item.used}</td>
						      <td>{$item.statuss}</td>
							  <td>{$item.use_time}</td>
							  <td><if condition="$item['status'] eq 2">已停止<else/><a href="{:U('Marketing/stopCoupons',array('id'=>$item['id']))}">停止发券</a></if><!-- <a href="营销系统-优惠券管理-新增优惠券.html">编辑</a><a>删除</a> --></td>
							</tr>
						</volist>
					</tbody>
				</table>
			</div>
			
			<div class="page">
	            {$_page}
	        </div>
			
			
		</div>
		
		
		
	</div>
		
		
	
	
	
	
	
	
</body>
</html>
